﻿
using System;
using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;
[Table("Loai")]
    public  class Loai
    {
        [Key]
        [DatabaseGenerated(DatabaseGeneratedOption.Identity)]
        public int Id { get; set; }
    [Required(ErrorMessage="Tên loại không để trống")]
        public string Tenloai { get; set; }
    
        public virtual ICollection<Sanpham> Sanphams { get; set; }
    }

